package com.atguigu05._super;

/**
 * ClassName: Person
 * Package: com.atguigu05._super
 * Description:
 *
 * @Author 姜
 * @Create 2023/11/22 10:31
 * @Version 1.0
 */
public class Person {
    // 属性
    String name;
    private int age;
    int id = 10001; // 身份证号

    public Person() {
        System.out.println("Person()...");
    }

    public Person(String name, int age) {
        this.name = name;
        this.age = age;
    }

    public Person(String name, int age, int id) {
        this.name = name;
        this.age = age;
        this.id = id;
    }

    // 方法
    public void eat(){
        System.out.println("干饭");
    }
    public void sleep(){
        System.out.println("睡觉");
    }
    public void doSport(){
        System.out.println("生命在于运动");
    }
}
